package work.mediway.mdm.biz.service.biz.impl;

import com.baomidou.mybatisplus.extension.plugins.pagination.Page;
import com.baomidou.mybatisplus.extension.service.impl.ServiceImpl;

import org.springframework.stereotype.Service;
import org.springframework.transaction.annotation.Transactional;

import work.mediway.mdm.core.page.QueryRequest;
import work.mediway.mdm.biz.service.biz.SsConfigService;
import work.mediway.mdm.biz.entity.biz.SsConfig;
import work.mediway.mdm.biz.mapper.biz.SsConfigMapper;
import work.mediway.mdm.biz.vo.biz.SsConfigVO;

/**
 * @author zhongyj <1126834403@qq.com><br/>
 * @date 2021/1/26
 */
@Transactional(rollbackFor = Exception.class)
@Service
public class SsConfigServiceImpl extends ServiceImpl<SsConfigMapper, SsConfig> implements SsConfigService {

    @Override
    public Page<SsConfigVO> pageListConfig(String param, QueryRequest queryRequest) {
        Page<SsConfigVO> page = new Page<>(queryRequest.getCurrent(), queryRequest.getSize());
        page.setRecords(this.baseMapper.listConfig(page, param));
        return page;
    }
}
